package com.example.sunsg.okhttptest.roobo;

public class AppConfig {

    public static final String APP_NAME = "com.roobo.pudding.android";
    public static final String APP_OS = "android";
    public static final String APP_API_VER = "1.0";
    public static final String PRODUCTION_APP = "pudding1s.android";
    public static final String PRODUCTION_APP_CONFIG = "pudding1s.app.config.index";//"pudding1s.app.config"
    public static final String PRODUCTION_MASTER = "com.roobo.coreserver";
    /**  */
    public static boolean DEBUGGABLE = true;

    //开发环境
    public static final int DEV_ENV = 0;
    //测试环境
    public static final int TEST_ENV = 1;
    //线上环境
    public static final int ONLINE_ENV = 2;

    public static final String url_websocket_online = "wss://v3.roo.bo/ws";
    public static final String url_websocket_room_url_online = "https://v3.roo.bo";
    public static final String url_websocket_test = "wss://v3-test.roobo.net:8080/ws";
    public static final String url_websocket_room_url_test = "v3-test.roobo.net";

    public static String URL_WEBSOCKET = url_websocket_online;
    public static String URL_WEBSOCKET_ROOM_URL = url_websocket_room_url_online;

    public static final String url_dev = "http://dev.roobo.com.cn/pudding1s";
    public static final String url_test = "http://pd1s.roobo.net";
    public static final String url_online = "https://pds-api.roo.bo";

    public static String URL_HOST = url_test;

    //检查升级的相关接口使用的域名和其他接口不一样
    public static final String url_update_dev = "http://dev.roobo.com.cn/update";
    public static final String url_update_test = "http://update.roobo.net";
    public static final String url_update_online = "http://update.roo.bo/v1";

    public static String URL_UPDATE_HOST = url_update_online;

    //意见反馈的相关接口使用的域名和其他接口不一样
    public static final String url_feedback_dev = url_dev;
    public static final String url_feedback_test = url_test;
    public static final String url_feedback_online = "http://feedback.roo.bo/v1";

    public static String URL_FEEDBACK_HOST = url_update_dev;

    //打点上传
    public static final String url_statistics_dev = url_dev + "/logger";
    public static final String url_statistics_test = url_test + "/logger";
    public static final String url_statistics_online = "http://st.roo.bo/logger";

    public static String URL_STATISTICS_HOST = url_statistics_online;

    //app诊断日志上传
    public static final String url_diagnosis_dev = url_dev + "/logger";
    public static final String url_diagnosis_test = url_test + "/logger";
    public static final String url_diagnosis_online = "http://logger.roo.bo/logger";

    public static String URL_DIAGNOSIS_HOST = url_diagnosis_online;

    /**
     * 选择网络环境
     *
     * @param usingEnv
     */
    public static void chooseNethubCfg(int usingEnv) {
        if (usingEnv == DEV_ENV) {
            URL_HOST = url_dev;
            URL_UPDATE_HOST = url_update_dev;
            URL_FEEDBACK_HOST = url_feedback_dev;
            URL_STATISTICS_HOST = url_statistics_dev;
            URL_DIAGNOSIS_HOST = url_diagnosis_dev;
            URL_WEBSOCKET = url_websocket_test;
            URL_WEBSOCKET_ROOM_URL = url_websocket_room_url_test;
        } else if (usingEnv == TEST_ENV) {
            URL_HOST = url_test;
            URL_UPDATE_HOST = url_update_test;
            URL_FEEDBACK_HOST = url_feedback_test;
            URL_STATISTICS_HOST = url_statistics_test;
            URL_DIAGNOSIS_HOST = url_diagnosis_test;
            URL_WEBSOCKET = url_websocket_test;
            URL_WEBSOCKET_ROOM_URL = url_websocket_room_url_test;
        } else if (usingEnv == ONLINE_ENV) {
            URL_HOST = url_online;
            URL_UPDATE_HOST = url_update_online;
            URL_FEEDBACK_HOST = url_feedback_online;
            URL_STATISTICS_HOST = url_statistics_online;
            URL_DIAGNOSIS_HOST = url_diagnosis_online;
            URL_WEBSOCKET = url_websocket_online;
            URL_WEBSOCKET_ROOM_URL = url_websocket_room_url_online;
        }
    }

    /**
     * 渠道全名
     * 开发人员可以使用下面三个渠道，来决定使用开发，测试 或者 线上环境
     * pudding1s_company_dev_11000
     * pudding1s_company_alpha_11000
     * pudding1s_company_online_11000
     *///注意，开发人员修改完AppConfig.APP_CHANNEL_NAME变量不要提交//注意，开发人员修改完改变量不要提交//注意，开发人员修改完改变量不要提交
    public static String APP_CHANNEL_NAME = "pudding1s_company_alpha_11000"/*"pudding1s_guanwang_online_10000"*/;//注意，开发人员修改完改变量不要提交

    /**
     * 渠道号
     渠道	渠道号
     官网	10000
     应用宝	10001
     百度	10002
     百度91	10003
     百度安卓	10004
     小米	10005
     360	10006
     豌豆荚	10007
     内部开发测试	11000
     */
    public static int APP_CHANNEL_NUMBER = 10000;


    /**
     * 版本号1023
     */
    public static int CLIENT_VERSION_CODE;
    /**
     * 版本名 v1.0
     */
    public static String CLIENT_VERSION_NAME;

    /**
     * 免打扰开始时间
     */
    public static int DISTURB_TIME_START = 22;
    /**
     * 免打扰开始结束
     */
    public static int DISTURB_TIME_END = 8;

    /**
     * 屏幕宽度
     */
    public static int WINDOW_WIDTH = 0;
    /**
     * 屏幕高度
     */
    public static int WINDOW_HEIGHT = 0;

    /**
     * 文件存储目录
     */
    public static final String PATH = "/pudding/";
    public static final String PATH_PHOTO = PATH + "photo/";
    public static final String PATH_SER = PATH + "ser/";
    public static final String FILE_GUIDE = PATH_SER + "serGuide";
    public static final String PATH_VOICE = PATH + "voice/";
    public static final String PATH_TMP = PATH + "tmp/";
    public static final String PATH_SERIAL = PATH + "serial/";
    public static final String PATH_DOWNLOAD = PATH + "download/";
    public static final String PATH_LOG = PATH + "log/";
    public static final String PATH_CLOUD = PATH + "cloud/";
    public static final String PATH_UPDATE = PATH + "update/";
    public static final String PATH_RECORDE_VOICE = PATH + "recordevoice/";
    public static final String PATH_FAMILY_DYNAMICS = PATH + "familydynamics/";
    /**
     * 本地头像前缀
     */
    public static final String DEFAULT_AVATAR_PREFIX = "default:";
    /**
     * PD相关
     */
    public static final String PASSWORD_PREFIX = "geG^_s[3Kl";
    public static final String TOKEN_PREFIX_FIRST = "=i*KE;6:jh5:N=Ix0~";
    public static final String TOKEN_PREFIX_SECOND = ";E4`^e@V.g";
    public static final String VALID_CODE_PREFIX = "/1E8S7ErwRl8o2GS/";

    /**
     * 检查是否回家间隔
     */
    public static final long CHECKER_HOME_INTERVAl = 2 * 1000;

    /**
     * http建立连接超时时间
     */
    public static final int HTTP_TIMEOUT_CONNECTION = 1000 * 30;
    /**
     * http传输数据超时时间
     */
    public static final int HTTP_TIMEOUT_SOCKET = 1000 * 60;
    /**
     * http建立连接超时时间
     */
    public static final int HTTP_TIMEOUT_CONNECTION_LONG_TIME = 1000 * 60;
    /**
     * http传输数据超时时间
     */
    public static final int HTTP_TIMEOUT_SOCKET_LONG_TIME = 1000 * 60 * 3;

    /**
     * 获取验证码间隔
     */
    public static final int VALID_CODE_INPUT_INTERVAL = 60;

    /**
     * 上传图片大小
     */
    public static final int UPLOAD_PHOTO_SIZE = 480;
    /**
     * 裁剪图片最小限制
     */
    public static final int UPLOAD_PHOTO_CROP_MIN_SIZE = 100;
    /**
     * 布丁热点前缀
     */
    public static final String JUAN_MASTER_AP_NAME_PREFIX = "JUAN_";
    /**
     * 布丁热点密码
     */
    public static final String JUAN_MASTER_AP_PASSWORD = "juan3652014";

    /**
     * 连接到布丁热点，向布丁UDP广播配置信息端口
     */
    public static final int JUAN_MASTER_AP_PORT = 12345;
    /**
     * 连接到布丁热点，向布丁UDP广播配置信息地址
     */
    public static final String JUAN_MASTER_AP_ADDRESS = "192.168.43.1";

    /**
     * 局域网UDP广播端口
     */
    public static final int JUAN_LAN_BROADCAST_PORT = 12345;
    /**
     * 局域网UDP广播地址
     */
    public static final String JUAN_LAN_BROADCAST_HOST = "255.255.255.255";

    /**
     * ADB socket端口
     */
    public static final int JUAN_ADB_SOCKET_PORT = 28459;

    /**
     * 手机号长度
     */
    public static final int PHONE_LENGTH = 13;
    public static final int PHONE_TRIM_LENGTH = 11;
    /**
     * 密码长度最短
     */
    public static final int PASSWORD_MIN_LENGTH = 6;
    /**
     * 验证码长度
     */
    public static final int VCODE_LENGTH = 4;
    /**
     * TTS长度
     */
    public static final int TTS_LENGTH = 30;

    /**
     * app默认版本
     */
    public static final String DEFAULT_VERSION_NAME = "1.0";

    /**
     * packagename
     */
    public static final String DEFAULT_PACKAGE_NAME = "com.roobo.pudding";

    /**
     * 问答长度限制为30个汉字
     */
    public static final int QUESTION_MAX_LENGTH = 60;

    /**
     * 时间分隔符
     */
    public static final String TIME_SPLIT = "~";
    /**
     * 时间分隔符
     */
    public static final String TIME_HO_SPLIT = ":";

    /**
     * 成员管理，是自己，加固定显示头
     */
    public static final String MEM_MYSELF_NAME_HEAD = "(我)";

    /**
     * 只负责更新通过adb插线方式获取的masterId
     */
    public static String adbMasterId;

    /**
     * 键盘弹出起初高度
     */
    public static int KEYBOARD_DEFAULT_MIN_HEIGHT = 100;

    /**
     * guide database name
     */
    public static String GUIDE_DATABASE_NAME = "guide.db";
    /**
     * guide database version
     */
    public static int GUIDE_DATABASE_VERSION = 1;
    /**
     * guide database id
     */
    public static int GUIDE_DATABASE_ID = 1;

    public static String PAPER_TYPE_1 = "身份证";

    public static int POSTALCODE_LENGTH = 6;

    /**
     * 修改管理员每页显示的数量
     */
    public static final int NO_OF_EMOTICONS_PER_PAGE = 2;

    /**
     * 技能文案反馈
     */
    public static final String SKILL_REQ_HEAD = "你可以这样对我说 ";

    /**
     * https
     */
    public static final String URL_START_WITH_HTTPS = "https";

}
